<?php
define('_file_','a_list_user');
if ( !isGod() )
	if ( !getRights($mod,'full') )
		if ( !RegOL_getAccessFile(_file_) )
		{
			showMsg('Không có quyền truy cập vào trang này này !','ex','center');
			die();
		}
$sql = "SELECT um_user.*,user_nogrp_module.modname FROM um_user INNER JOIN user_nogrp_module ON um_user.username=user_nogrp_module.username WHERE user_nogrp_module.modname='$mod'";
$rs = $link->execute($sql);
echo '<div align="right" class="clsAdd"><img src="images/add_trans.gif" border="0" align="absmiddle">&nbsp;
<a href="admin.php?mod=' . $mod . '&act=a_get_user_from_other_mod">Thêm User từ Moduld khác</a> | <img src="images/add_trans.gif" border="0" align="absmiddle">&nbsp;<a href="admin.php?mod=' . $mod . '&act=a_add_user">Thêm user</a>&nbsp;</div>';
include('vsGrid.php');

$grd = new vsGrid($link,$server['mysql_db_name'],'um_user',$sql);
$grd->selectionRow = true;
$grd->enablePaging = true;
$grd->showFixCol = true;
$grd->fixColWidth = 20;
$grd->usingRecordsetForPaging = false;

$grd->arrHeader = array('Username','Tên thật','Email');
$grd->arrFieldName = array('username','realname','email');
$grd->arrAction = array(
'<img src="images/edit_trans.gif" border="0" align="absmiddle" alt="Hiệu chỉnh User">'=>'admin.php?mod=UManager&act=edit_user',
'<img src="images/delete_trans.gif" border="0" align="absmiddle" alt="Xóa">'=>'admin.php?mod=UManager&act=delete_user&url_redir=' . base64_encode("admin.php?mod=$mod&act=a_list_user"),
'<img src="images/permission.gif" border="0" align="absmiddle" alt="Cấp quyền">'=>'admin.php?mod=RegisterSubject&act=a_permission_touser'
);
$grd->arrParams = array('un'=>'username,f');
$grd->idxDel = 2;
$grd->grdRender();

?>
